WIP: display why I can't change the chat agent#216
Closed
teto wants to merge 1 commit intoRobitx:mainfrom
Closed
Conversation
Owner
|
Agents are currently a bundle of model settings and a system prompt leading to some agents being good for chats, while others for code operations. The bundling is there, because different LLMs (and different tasks) might have different needs. In general, it's better to have a lower temperature for coding (less hallucinations) and weaker models (like llama) might need a different/custom sys prompt to force it work properly. In a chat buffer {
name = "ChatGPT4o",
chat = true,
command = false,
-- string with model name or table with model name and parameters
model = { model = "gpt-4o", temperature = 1.1, top_p = 1 },
-- system prompt (use this to specify the persona/role of the AI)
system_prompt = require("gp.defaults").chat_system_prompt,
},
{
provider = "openai",
name = "CodeGPT4o",
chat = false,
command = true,
-- string with model name or table with model name and parameters
model = { model = "gpt-4o", temperature = 0.8, top_p = 1 },
-- system prompt (use this to specify the persona/role of the AI)
system_prompt = require("gp.defaults").code_system_prompt,
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
for some reason,
GpAgentrefused to autocomplete ChatGPT. Looking at the code, it refused to set the chat agent under some conditions (Is this a new behavior ?).:GpAgent ChatGPT4owould returnChatGPT4o is not a valid agent for current buffer"which is not very helpful (why ? how can I fix this). I've refactored not_chat to remove the negation intois_chatwith a return pattern used widely in luarockreturn success (boolean), err_msg.So right now I can see why it refuses to change:
I am still not sure why we want to prevent that